As one of digital interfaces that can transfer moving image data, a USB interface is known. The USB interface is a digital interface complying with the USB (Universal Serial Bus) standard (see, for example, “Universal Serial Bus Specification Revision 2.0, Apr. 27, 2000”).
In the USB standard, a transfer method called isochronous transfer is specified to guarantee real-time moving image transfer. Also, the USB standard specifies that a host controller transmits a sync signal called start-of-frame (SOF) to respective devices. A device that transfers moving image data transfers moving image data by isochronous transfer in synchronism with SOF, thus allowing real-time transfer of moving image. When isochronous transfer is made, a bandwidth for transfer must be assured. However, in case of the USB standard, each device notifies the host controller of an alternate setting interface, which indicates a bandwidth required for isochronous data transfer, using a descriptor, and the host controller selects an alternate setting interface using a Set_Interface request to each device, thus assuring the bandwidth.
FIG. 1 is a schematic view of a descriptor held by a device which transfers moving image data by isochronous transfer. Reference numeral 101 denotes a device descriptor used to notify a vendor ID, product ID, and the like; 102, a configuration descriptor used to notify the configuration that the device can assume; 103, a descriptor indicating alternate setting 0 of interface #1 used in the configuration 102; and 104, an end point descriptor used by the interface 103 (MaxPavload that indicates the bandwidth as isochronous transfer type is 0). Reference numeral 105 denotes an interface descriptor which indicates alternate setting 1 of interface #1; and 106, an end point descriptor when interface #1 is selected as alternate setting 1 (MaxPavload that indicates the bandwidth as isochronous transfer type is 512). Therefore, when the host controller selects alternate setting 1 of interface #1 using a Set_Interface request shown in FIG. 2, data transfer for 512 bytes are guaranteed for a period of each SOF (1-ms period in case of Full Speed (USB standard); 125-μs period in case of High Speed), and a device which holds this descriptor can isochronously transfer data.
The USB standard has no specification of data in isochronous transfer, and data to be transferred is not limited. That is, devices must exchange information about a data format and the like. For example, in the USB standard, a host controller device as a transfer destination can be notified of a stream data format to be isochronously transferred using a descriptor.
FIG. 3 shows an example of a descriptor used to notify a host controller of the stream format used in transfer. Reference numeral 301 denotes a descriptor length; and 302 and 303, a descriptor type indicating, e.g., a descriptor used to notify the stream format. Reference numerals 304 and 305 denote an identifier indicating the stream format to be transmitted as isochronous data. The host controller reads these values to recognize the stream format used in transmission of a device that holds the descriptor of FIG. 3, thus processing the received stream data.
FIG. 4 is a chart simply showing the data flow upon supplying moving image data on USB. A host acquires a descriptor indicating the stream format from a device using Get Descriptor (step 401), and changes an alternate setting to 1 using Set Interface (step 402). After that, the host transmits IN TOKEN to the device for each SOF (steps 403 to 405), and the device isochronously transfers data to be transferred (Iso data) to the host after reception of IN TOKEN (steps 406 to 408).
FIG. 5 time-serially shows the data flow on USB. SOF 51 is transmitted from a host to have a width 504 for 1 ms (125 μs in case of High Speed), and IN TOKEN 502 is similarly transferred from the host to an isochronous end point of a device. The device transfers data 503 via the isochronous end point after IN TOKEN 502. The device can transmit data in response to IN TOKEN for each period. When it becomes impossible to make data transfer at the timing of 505, the device can skip data transfer, and can transfer data in the next period.
When real-time data transfer is made using the USB interface, a bus bandwidth must be assured for transfer to guarantee realtimeness.